package cn.itsource.exam.service;

import cn.itsource.exam.domain.Permission;
import cn.itsource.exam.domain.Permission;
import cn.itsource.exam.query.PermissionQueryVo;
import cn.itsource.exam.util.PageList;

import java.util.List;
import java.util.Map;

public interface IPermissionService {

    void deletePermission(Long id);

    void insertPermission(Permission Permission);

    void updatePermission(Permission Permission);

    Permission selectPermissionByPermissionId(Long PermissionId);

    PageList<Permission> selectPermission(PermissionQueryVo PermissionQueryVo);

    Permission selectPermissionByName(Permission Permission);

    void batchDeletePermission(Long[] PermissionIds);

    Map<String ,Object> getAllPermissionsByRoleId(Long roleId);

    List<Permission> selectAllPermission();

    //保存角色权限关系
    void addRolePermission(Long rid, Long[] pids);
    //根觉用户id查对应得菜单
    List<Permission> getPermissionByUserId(String id);
}
